package com.ala4.oxcafe.entity;

import com.ala4.oxcafe.core.entity.BaseEntity;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

/**
 * 地址库信息对象
 *
 * @author PING
 * @date 2025-03-27
 */
@Data
@TableName("region_info")
@Schema(description = "地址库信息实体")
@JsonIgnoreProperties(value = {"createBy", "createTime", "updateBy", "updateTime", "remark", "delFlag", "version"})
public class RegionInfo extends BaseEntity {

    private static final long serialVersionUID = 1L;

    @TableId
    private String regionCode;

    @Schema(description = "地区名称")
    @TableField("region_name")
    private String regionName;

    @Schema(description = "地区全称")
    @TableField("region_all_name")
    private String regionAllName;

    @Schema(description = "上级地址")
    @TableField("region_parent")
    private String regionParent;

    @Schema(description = "默认值(预留)")
    @TableField("region_initialition")
    private String regionInitialition;

    @Schema(description = "首字母")
    @TableField("region_spell")
    private String regionSpell;

    @Schema(description = "类型：1是省会，2直辖市,3港澳台,4其它")
    @TableField("region_type")
    private Long regionType;

    @Schema(description = "同级下排序")
    @TableField("region_order")
    private Long regionOrder;

    @Schema(description = "0全国、1省、2市区、3郊县、4街道、5居委会")
    @TableField("region_level")
    private Long regionLevel;

    @Schema(description = "备注")
    @TableField("region_remark")
    private String regionRemark;

    @Schema(description = "城乡分类代码")
    @TableField("village_type")
    private String villageType;

    @Schema(description = "所属国家名")
    @TableField("nation_name")
    private String nationName;

    @Schema(description = "所属省名称")
    @TableField("province_name")
    private String provinceName;

    @Schema(description = "所属市名称")
    @TableField("city_name")
    private String cityName;

    @Schema(description = "所属区县名称")
    @TableField("county_name")
    private String countyName;

    @Schema(description = "所属街道名称")
    @TableField("town_name")
    private String townName;

    @Schema(description = "经度")
    @TableField("lng")
    private String lng;

    @Schema(description = "纬度")
    @TableField("lat")
    private String lat;

    @Schema(description = "来源地图，百度1,高德2")
    @TableField("maptype")
    private Long maptype;

    @TableField(exist = false)
    @Schema(description = "小于某个地址等级")
    private String lessThanRegionLevel;

}
